//
//  EditMyInfoTableViewCell.m
//  TravelFollowYourHeart
//
//  Created by appleLJ on 2017/12/12.
//  Copyright © 2017年 Lwx. All rights reserved.
//

#import "EditMyInfoTableViewCell.h"

@interface EditMyInfoTableViewCell ()

@property(nonatomic,strong) UILabel *titleLabel;

@end

@implementation EditMyInfoTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        self.separatorInset = UIEdgeInsetsZero;
        self.selectionStyle = UITableViewCellSelectionStyleNone;

        [self.contentView addSubview:self.titleLabel];
        
        __weak __typeof(self)weakSelf = self;
        [self.titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.equalTo(weakSelf).offset(10 / WIDTH_5S_SCALE);
            make.centerY.equalTo(weakSelf);
        }];
        
    }
    return self;
}

#pragma mark -- init

- (UILabel *)titleLabel{
    if (!_titleLabel) {
        _titleLabel = [[UILabel alloc] init];
        _titleLabel.font = DEF_FontSize_14;
        _titleLabel.textColor = getColor(blackColor);
        _titleLabel.textAlignment = NSTextAlignmentLeft;
    }
    return _titleLabel;
}

//setter

- (void)setModel:(NSDictionary *)model{
    _model = model;
    self.titleLabel.text = model[@"title"];
}

@end
